<script>
    export default {
        data() {
            return {
                children: [{
                    name : 'Button',
                    data : {
                        type : 'primary'
                    }
                }]
            };
        },
        render(h){
            var arr = [];
            for (var i = 0; i < this.children.length; i++) {
                var child = this.children[i];
                arr.push(
                    h(
                        child.name,   // tag name 标签名称
                        {
                            props : child.data
                        }
                    )
                )
            }
            return h(
                'div',
                {},
                arr
            )

        },
        mounted(){
            window.diagramVM = this;
        },
        methods: {
        }
    };
</script>